﻿using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Text;

namespace BitPongTetris
{
    class BitPongOutput
    {
        public static void PrintField(long field, int dx)
        {
            Console.WriteLine(GetFieldToPrint(field, dx));
            Console.ReadKey();
        }

        static string GetFieldToPrint(long field, int dx)
        {
            StringBuilder result = new StringBuilder();

            using (StringWriter writer = new StringWriter(result))
            {
                writer.WriteLine("dx = {0}", dx);
                for (int bit = 0; bit < 64; bit++)
                {
                    writer.Write("{0}", ((field >> bit) & 1) == 1 ? '*' : '.');

                    if (bit % 4 == 3)
                    {
                        writer.WriteLine();
                    }
                }
            }

            return result.ToString();
        }
    }
}
